Skip to content

Conversation

@leakingmemory
Copy link

Apparently the system stub was removed from boost 1.89. This causes projects depending on cpprestsdk to fail to build in case they use cmake to find and configure cpprestsdk.

@PPN-SD
Copy link

PPN-SD commented Jan 21, 2026

@leakingmemory
Copy link
Author

Sure there might be permutations of this depending on the target platform and similar. But just to confirm, it failed to find boost (specificly Boost::system) and removing Boost::system from the file fixed it?

Just to clarify, I'm the maintainer of the FreeBSD port now, and I at least intermittently observed issues that were solved by the original patch while trying to build for the new FreeBSD 15.0 in december.

@PPN-SD
Copy link

PPN-SD commented Jan 25, 2026

But just to confirm, it failed to find boost (specificly Boost::system) and removing Boost::system from the file fixed it?

Yes. Because boost_system is header only since a while (1.69) and the stub lib is now removed as you said.

@leakingmemory
Copy link
Author

Yes, if you want me to add it to the PR, could you perhaps provide error messages for verification? Which platform are you building for?

@PPN-SD
Copy link

PPN-SD commented Jan 25, 2026

Linux Gentoo boost-1.89.0 cmake-4.2.1:

- Found websocketpp version 0.8.2 on system
CMake Warning (dev) at Release/cmake/cpprest_find_boost.cmake:49 (find_package):
  Policy CMP0167 is not set: The FindBoost module is removed.  Run "cmake
  --help-policy CMP0167" for policy details.  Use the cmake_policy command to
  set the policy and suppress this warning.

Call Stack (most recent call first):
  Release/cmake/cpprest_find_websocketpp.cmake:17 (cpprest_find_boost)
  Release/src/CMakeLists.txt:68 (cpprest_find_websocketpp)
This warning is for project developers.  Use -Wno-dev to suppress it.

CMake Error at /usr/lib64/cmake/Boost-1.89.0/BoostConfig.cmake:141 (find_package):
  Could not find a package configuration file provided by "boost_system"
  (requested version 1.89.0) with any of the following names:

    boost_systemConfig.cmake
    boost_system-config.cmake

  Add the installation prefix of "boost_system" to CMAKE_PREFIX_PATH or set
  "boost_system_DIR" to a directory containing one of the above files.  If
  "boost_system" provides a separate development package or SDK, be sure it
  has been installed.
Call Stack (most recent call first):
  /usr/lib64/cmake/Boost-1.89.0/BoostConfig.cmake:262 (boost_find_component)
  /usr/share/cmake/Modules/FindBoost.cmake:610 (find_package)
  Release/cmake/cpprest_find_boost.cmake:49 (find_package)
  Release/cmake/cpprest_find_websocketpp.cmake:17 (cpprest_find_boost)
  Release/src/CMakeLists.txt:68 (cpprest_find_websocketpp)

@leakingmemory
Copy link
Author

Thanks. With boost-1.89 unmasked I guess. I'll probably be able to reproduce it as I am using Gentoo as well.

@leakingmemory leakingmemory changed the title Boost 1.89 removed the system stub Boost 1.89: removed system stub, deadline_timer error Jan 25, 2026
@leakingmemory
Copy link
Author

Also testing replacing deadline_timer (header not included, also deprecated) with steady_timer:

/var/tmp/portage/dev-cpp/cpprestsdk-2.10.19-r8/work/cpprestsdk-2.10.19/Release/src/http/client/http_client_asio.cpp:470:18: error: ‘deadline_timer’ in namespace ‘boost::asio’ does not name a type
470 | boost::asio::deadline_timer m_pool_epoch_timer;
| ^~~~~~~~~~~~~~

since it is no longer included by the other includes anymore. But
dealine_timer is deprecated, so I suggest replacing it with steady_timer
like this.
@leakingmemory
Copy link
Author

With regards to Gentoo Linux I'm testing an updated patch for dev-cpp/cpprestsdk::guru . I have the changes staged locally so just test building with boost-1.88 now. I expect to commit the changes if they work with 1.88 as well within the next 24hrs to the guru dev-branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants